<?php

/**
 * Commentaires form.
 *
 * @package    explications_informatiques
 * @subpackage form
 * @author     Guimezanes Cyrille
 * @version    SVN: $Id: sfDoctrineFormTemplate.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class CommentairesForm extends BaseCommentairesForm
{
  public function configure()
  {
	  $this->disableLocalCSRFProtection();
  }
  public function setup()
  {
    $this->setWidgets(array(
      'idcommentaires' => new sfWidgetFormInputHidden(),
      'id_asso'        => new sfWidgetFormInputHidden(),
      'texte'          => new sfWidgetFormTextarea(array(),array("rows" => 5, "cols" => 90)),
    ));

    $this->setValidators(array(
      'idcommentaires' => new sfValidatorString(array('required' => false)),
      'id_asso'        => new sfValidatorString(array('required' => false)),
      'texte'          => new sfValidatorString(array('required' => false)),
    ));
	$this->widgetSchema->setLabels(array(
	  'texte'		   => " ",
    ));
    $this->widgetSchema->setNameFormat('commentaire[%s]');

  }
}
